package com.xinqi.modules.sys.config.controller.inner;

import com.xinqi.common.base.response.R;
import com.xinqi.common.core.web.controller.BaseController;
import com.xinqi.modules.sys.config.service.ISysConfigService;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 参数配置 信息操作处理
 *
 * @author dgyu
 */
@RequiredArgsConstructor
@RestController
@RequestMapping("/inner/config")
public class SysConfigInnerController extends BaseController {

    private final ISysConfigService configService;

    @GetMapping(value = "/configKey/{configKey}")
    public R<String> getConfigKey(@PathVariable("configKey") String configKey) {
        return R.data(configService.selectConfigByKey(configKey), "获取成功");
    }

}
